/* 引入中文字体 */
@import url('https://fonts.googleapis.com/css2?family=EB+Garamond:wght@400;500;600;700&display=swap');

/* 基本重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

/* 中国传统色彩变量 - 浅色模式 */
:root {
    --paper: #F5F5F0; /* 月白 */
    --ink: #2A2A2A; /* 墨色 */
    --ochre: #9C6E5B; /* 赭石 */
    --cinnabar: #C53D2D; /* 朱砂 */
    --azurite: #2F6B7A; /* 石青 */
    --bamboo: #88A96B; /* 竹青 */
    --ivory: #FFF8E7; /* 象牙白 */
    --ink-light: #4A4A4A; /* 淡墨 */
    --background-light: rgba(248, 248, 245, 0.7);
    --border-light: #e6e3dd;
    --shadow-light: rgba(0, 0, 0, 0.05);
    --shadow-medium: rgba(0, 0, 0, 0.1);
    --shadow-dark: rgba(0, 0, 0, 0.15);
}

/* 深色模式变量 */
[data-theme="dark"] {
    --paper: #1A1A1A; /* 墨黑 */
    --ink: #E0E0E0; /* 月白 */
    --ochre: #B8860B; /* 赭石金 */
    --cinnabar: #DC4026; /* 朱砂红 */
    --azurite: #5F9EA0; /* 石青浅 */
    --bamboo: #90EE90; /* 竹青绿 */
    --ivory: #2A2A2A; /* 深灰 */
    --ink-light: #B0B0B0; /* 淡灰 */
    --background-light: rgba(42, 42, 42, 0.7);
    --border-light: #404040;
    --shadow-light: rgba(0, 0, 0, 0.3);
    --shadow-medium: rgba(0, 0, 0, 0.4);
    --shadow-dark: rgba(0, 0, 0, 0.5);
}

body {
    font-family: 'EB Garamond', 'SimSun', serif;
    line-height: 1.6;
    color: var(--ink);
    background-color: var(--paper);
    position: relative;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* 宣纸纹理背景 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* 底层：宣纸微纹理 */
    background-color: var(--paper);
    background-image: 
        /* 中层：诗词浮水印 */
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='600' viewBox='0 0 200 600'%3E%3Ctext x='90' y='100' font-family='SimSun' font-size='14' fill='%232A2A2A' fill-opacity='0.15' transform='rotate(90, 100, 300)'%3E风萧萧兮易水寒%3C/text%3E%3Ctext x='100' y='200' font-family='SimSun' font-size='14' fill='%232A2A2A' fill-opacity='0.15' transform='rotate(90, 100, 300)'%3E壮士一去兮不复还%3C/text%3E%3Ctext x='110' y='300' font-family='SimSun' font-size='14' fill='%232A2A2A' fill-opacity='0.15' transform='rotate(90, 100, 300)'%3E天生我材必有用%3C/text%3E%3Ctext x='120' y='400' font-family='SimSun' font-size='14' fill='%232A2A2A' fill-opacity='0.15' transform='rotate(90, 100, 300)'%3E千金散尽还复来%3C/text%3E%3C/svg%3E");
    opacity: 0.7;
    z-index: -2;
    transition: background-color 0.3s ease;
}

/* 深色模式下修改水印颜色 */
[data-theme="dark"] body::before {
    background-image: 
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='600' viewBox='0 0 200 600'%3E%3Ctext x='90' y='100' font-family='SimSun' font-size='14' fill='%23E0E0E0' fill-opacity='0.1' transform='rotate(90, 100, 300)'%3E风萧萧兮易水寒%3C/text%3E%3Ctext x='100' y='200' font-family='SimSun' font-size='14' fill='%23E0E0E0' fill-opacity='0.1' transform='rotate(90, 100, 300)'%3E壮士一去兮不复还%3C/text%3E%3Ctext x='110' y='300' font-family='SimSun' font-size='14' fill='%23E0E0E0' fill-opacity='0.1' transform='rotate(90, 100, 300)'%3E天生我材必有用%3C/text%3E%3Ctext x='120' y='400' font-family='SimSun' font-size='14' fill='%23E0E0E0' fill-opacity='0.1' transform='rotate(90, 100, 300)'%3E千金散尽还复来%3C/text%3E%3C/svg%3E");
}

/* 纸张纤维质感 */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%232A2A2A' fill-opacity='0.03' fill-rule='evenodd'/%3E%3C/svg%3E");
    opacity: 0.5;
    z-index: -1;
    transition: background-color 0.3s ease;
}

/* 深色模式下修改纤维质感颜色 */
[data-theme="dark"] body::after {
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23E0E0E0' fill-opacity='0.03' fill-rule='evenodd'/%3E%3C/svg%3E");
}

/* 主题切换按钮样式 */
.theme-toggle {
    background: var(--paper);
    border: 1px solid var(--ochre);
    color: var(--ink);
    padding: 0.5rem 1rem;
    cursor: pointer;
    border-radius: 2px;
    transition: all 0.3s ease;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: 1rem;
}

.theme-toggle:hover {
    background: var(--ivory);
    color: var(--cinnabar);
    border-color: var(--cinnabar);
}

/* 书本图标样式 */
.book-icon {
    position: absolute;
    font-size: 2rem;
    color: var(--ochre);
    cursor: pointer;
    z-index: 10;
    transition: transform 0.3s ease, color 0.3s ease;
    animation: float 3s ease-in-out infinite;
    opacity: 0.8;
}

/* 书本图标浮动动画 - 保留旋转角度的同时进行浮动 */
@keyframes float {
    0% {
        transform: translateY(0) rotate(var(--book-rotation, 0deg));
    }
    50% {
        transform: translateY(-10px) rotate(var(--book-rotation, 0deg));
    }
    100% {
        transform: translateY(0) rotate(var(--book-rotation, 0deg));
    }
}

/* 书本图标悬停效果 - 保留旋转角度 */
.book-icon:hover {
    color: var(--cinnabar);
    transform: scale(1.1) rotate(var(--book-rotation, 0deg));
    animation-play-state: paused;
}

/* 书本内容样式 */
.book-content {
    position: absolute;
    background-color: var(--ivory);
    border: 1px solid var(--ochre);
    border-radius: 5px;
    padding: 1rem;
    width: 250px;
    max-width: 80vw;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    z-index: 20;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
}

/* 书本内容显示样式 */
.book-content.show {
    opacity: 1;
    visibility: visible;
}

/* 书本内容标题 */
.book-content h4 {
    font-size: 1.1rem;
    color: var(--cinnabar);
    margin-bottom: 0.5rem;
    border-bottom: 1px solid var(--ochre);
    padding-bottom: 0.5rem;
}

/* 书本内容段落 */
.book-content p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0;
    text-indent: 0;
}

/* 书本图标不同位置的浮动延迟 */
.book-icon:nth-child(1) {
    animation-delay: 0s;
}

.book-icon:nth-child(2) {
    animation-delay: 0.5s;
}

.book-icon:nth-child(3) {
    animation-delay: 1s;
}

.book-icon:nth-child(4) {
    animation-delay: 1.5s;
}

.book-icon:nth-child(5) {
    animation-delay: 2s;
}

/* 容器样式 */
.container {
    width: 80%;
    margin: 0 auto;
    padding: 2rem 0;
}

/* 标题样式 - 宋体字韵 */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 1rem;
    color: var(--ink);
    font-family: 'SimSun', 'EB Garamond', serif;
}

/* 古籍标题样式 */
h1 {
    font-size: 2.8rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--ink);
    position: relative;
}

/* 主标题 - 古籍经折装风格 */
h2 {
    font-size: 2.2rem;
    text-align: center;
    margin-bottom: 2.5rem;
    padding-bottom: 1rem;
    position: relative;
    color: var(--ink);
    font-weight: 600;
    letter-spacing: 0.1em;
}

/* 栏线装饰 */
h2::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 10%;
    width: 20%;
    height: 1px;
    background-color: var(--ochre);
    opacity: 0.6;
}

h2::after {
    content: '';
    position: absolute;
    top: 50%;
    right: 10%;
    width: 20%;
    height: 1px;
    background-color: var(--ochre);
    opacity: 0.6;
}

/* 朱砂印章装饰 */
h2::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background-color: var(--cinnabar);
    opacity: 0.7;
    z-index: 1;
}

/* 小节标题 */
h3 {
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--ochre);
    border-bottom-width: 2px;
    border-bottom-style: solid;
    border-image: linear-gradient(to right, var(--cinnabar), transparent) 1;
    color: var(--ink);
    font-weight: 600;
    letter-spacing: 0.05em;
}

/* 副标题 */
h4 {
    font-size: 1.2rem;
    color: var(--ochre);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* 段落样式 - 仿古籍排版 */
p {
    margin-bottom: 1.5rem;
    text-align: justify;
    line-height: 1.8;
    text-indent: 2em; /* 段首空两格 */
    color: var(--ink);
    font-size: 1.05rem;
}

/* 引用区块 - 竖排排版 */
blockquote {
    position: relative;
    padding: 1.5rem 2rem;
    margin: 2rem 0;
    background-color: var(--ivory);
    border-left: 3px solid var(--cinnabar);
    font-style: italic;
    quotes: "" "";
}

blockquote::before,
blockquote::after {
    content: '「';
    position: absolute;
    font-size: 4rem;
    color: var(--cinnabar);
    opacity: 0.2;
    font-style: normal;
    line-height: 1;
}

blockquote::before {
    top: -20px;
    left: 10px;
}

blockquote::after {
    content: '」';
    bottom: -40px;
    right: 10px;
}

/* 链接样式 - 朱砂点缀 */
a {
    color: var(--azurite);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    font-weight: 500;
}

/* 传统毛笔效果 */
a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--cinnabar);
    transition: width 0.3s ease;
}

a:hover {
    color: var(--cinnabar);
}

a:hover::after {
    width: 100%;
}

/* 按钮样式 - 古籍书签风格 */
.btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    background-color: var(--paper);
    color: var(--ink);
    border: 1px solid var(--ochre);
    border-radius: 0;
    cursor: pointer;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    font-family: 'SimSun', serif;
    letter-spacing: 0.05em;
}

/* 书签装饰角 */
.btn::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 20px;
    height: 20px;
    background-color: var(--cinnabar);
    opacity: 0.8;
    clip-path: polygon(100% 0, 0 0, 100% 100%);
    transition: opacity 0.3s ease;
}

.btn:hover {
    background-color: var(--ivory);
    color: var(--cinnabar);
    border-color: var(--cinnabar);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn:hover::before {
    opacity: 1;
}

/* 导航栏样式 - 线装书标签风格 */
header {
    background-color: var(--paper);
    border-bottom: 1px solid var(--ochre);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 5%;
    position: relative;
}

/* 古籍书名风格 */
.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--ink);
    font-family: 'SimSun', serif;
    letter-spacing: 0.1em;
    position: relative;
    padding-right: 25px;
}

/* 印章装饰 */
.logo::after {
    content: '印';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-color: var(--cinnabar);
    color: white;
    border-radius: 2px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'SimSun', serif;
}

/* 导航链接 - 线装书标签风格 */
.nav-links {
    display: flex;
    list-style: none;
    position: relative;
}

.nav-links li {
    margin-left: 2.5rem;
    position: relative;
}

/* 线装书标签样式 */
.nav-links a {
    color: var(--ink);
    font-weight: 500;
    position: relative;
    padding: 0.5rem 0;
    font-family: 'SimSun', serif;
    letter-spacing: 0.05em;
    transition: all 0.3s ease;
}

/* 标签悬停效果 */
.nav-links a:hover {
    color: var(--cinnabar);
    transform: translateY(-2px);
}

/* 标签装饰线 */
.nav-links a::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 10px;
    height: 5px;
    background-color: var(--cinnabar);
    opacity: 0;
    transition: all 0.3s ease;
}

.nav-links a:hover::before {
    opacity: 1;
    width: 20px;
}

/* 标签下划线 - 毛笔效果 */
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--cinnabar);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* 语言切换按钮样式 - 古籍页角风格 */
.language-switch {
    display: flex;
    align-items: center;
    margin-left: 2rem;
    border: none; /* 去除边框 */
    border-radius: 0;
    overflow: hidden;
    box-shadow: none;
    padding: 0;
    margin: 0;
    margin-left: 2rem;
}

.lang-btn {
    padding: 8px 15px;
    border: none; /* 去除按钮边框 */
    background: var(--paper);
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    color: var(--ink);
    font-family: 'SimSun', serif;
    position: relative;
}

.lang-btn.active {
    background-color: var(--cinnabar);
    color: white;
}

.lang-btn:hover:not(.active) {
    background-color: var(--ivory);
    color: var(--cinnabar);
}

/* 深色模式下语言切换按钮颜色 */
[data-theme="dark"] .lang-btn {
    color: #D2B48C; /* 深色橡木色 */
}

[data-theme="dark"] .lang-btn.active {
    color: #D2B48C; /* 深色橡木色 */
    font-weight: bold;
}

[data-theme="dark"] .lang-btn:hover {
    color: var(--cinnabar);
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px 0;
    background-color: #333;
    transition: all 0.3s ease;
}

/* 英雄区域样式 - 水墨意境 */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(rgba(42, 42, 42, 0.6), rgba(42, 42, 42, 0.7)), url('images/hero-bg.jpg') center/cover no-repeat;
    color: var(--paper);
    padding-top: 60px;
    position: relative;
    overflow: hidden;
}

/* 水墨晕染效果 */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100%25' height='100%25'%3E%3Cdefs%3E%3CradialGradient id='watercolor' cx='50%25' cy='50%25' r='70%25' fx='50%25' fy='50%25'%3E%3Cstop offset='0%25' style='stop-color:%232A2A2A;stop-opacity:0.3'/%3E%3Cstop offset='100%25' style='stop-color:%23F5F5F0;stop-opacity:0.05'/%3E%3C/radialGradient%3E%3C/defs%3E%3Crect width='100%25' height='100%25' fill='url(%23watercolor)'/%3E%3C/svg%3E");
    opacity: 0.8;
}

/* Minecraft 相关样式 */
.minecraft-text {
    color: #527F30;
    font-weight: bold;
    position: relative;
    display: inline-block;
    font-family: 'SimSun', serif;
}

.minecraft-text::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #71A638;
    opacity: 0.8;
}

.minecraft-icon {
    color: #527F30;
    transform: rotate(5deg);
    display: inline-block;
}

/* Minecraft 装饰方块 */
.minecraft-decoration {
    position: fixed;
    width: 40px;
    height: 40px;
    z-index: -1;
    opacity: 0.7;
    background-size: contain;
    background-repeat: no-repeat;
    pointer-events: none;
}

.grass-block {
    top: 20px;
    right: 20px;
    background-color: #527F30;
    border: 2px solid #71A638;
}

.grass-block::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40%;
    background-color: #8B5A2B;
}

.dirt-block {
    bottom: 20px;
    left: 20px;
    background-color: #8B5A2B;
    border: 2px solid #6A4625;
}

.wood-block {
    top: 50%;
    left: 20px;
    background-color: #A0522D;
    border: 2px solid #8B4513;
}

/* Minecraft 经历特殊样式 */
.minecraft-experience .timeline-content h4 i {
    animation: minecraft-wobble 2s ease-in-out infinite;
}

@keyframes minecraft-wobble {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(5deg); }
    75% { transform: rotate(-5deg); }
}

.hero-content {
    max-width: 800px;
    padding: 0 2rem;
    position: relative;
    z-index: 1;
    animation: fadeIn 1.5s ease-out;
}

/* 古籍标题效果 */
.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--paper);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    position: relative;
    display: inline-block;
}

/* 朱砂点睛 */
.highlight {
    color: var(--cinnabar);
    font-weight: 800;
    position: relative;
    display: inline-block;
}

/* 朱砂装饰 */
.highlight::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--cinnabar);
    opacity: 0.8;
}

.hero p {
    font-size: 1.4rem;
    margin-bottom: 3rem;
    text-align: center;
    opacity: 0.9;
    line-height: 1.8;
    text-indent: 0;
    font-family: 'SimSun', serif;
    color: var(--paper);
}

/* 关于我区域样式 - 古籍章节风格 */
.about {
    padding: 8rem 0;
    background-color: var(--paper);
    position: relative;
    overflow: hidden;
}

/* 古籍栏线装饰 */
.section-header::after {
    content: '';
    display: block;
    width: 80px;
    height: 2px;
    background-color: var(--cinnabar);
    margin: 1rem auto 0;
    position: relative;
}

.section-header::before {
    content: '';
    display: block;
    width: 40px;
    height: 1px;
    background-color: var(--ochre);
    margin: 0.5rem auto 0;
}

.about-content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4rem;
    position: relative;
}

.about-img {
    flex: 1;
    min-width: 300px;
    text-align: center;
    position: relative;
}

.about-img img {
    width: 280px;
    height: 280px;
    border: 15px solid white;
    object-fit: cover;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transform: rotate(-1deg);
}

.about-text {
    flex: 2;
    min-width: 300px;
    position: relative;
    padding: 2rem;
    background-color: rgba(248, 248, 245, 0.7);
    border: 1px solid #e6e3dd;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
}

/* 宣纸边缘效果 */
.about-text::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%239C6E5B' fill-opacity='0.05' fill-rule='evenodd'/%3E%3C/svg%3E");
    opacity: 0.3;
    pointer-events: none;
}

.skills {
    margin-top: 2.5rem;
}

.skill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1.5rem;
}

/* 闲章技能标签 */
.skill-list span {
    background-color: var(--paper);
    padding: 0.6rem 1.2rem;
    border-radius: 2px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid var(--ochre);
    color: var(--ink);
    position: relative;
    transition: all 0.3s ease;
    transform: rotate(-1deg);
    font-family: 'SimSun', serif;
    display: inline-flex;
    align-items: center;
}

.skill-list span i {
    margin-right: 0.5rem;
    font-size: 1.1em;
    color: var(--cinnabar);
}

.skill-list span:hover {
    transform: rotate(1deg) scale(1.05);
    background-color: var(--ivory);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* 技能级别样式 - 传统色彩 */
.skill-level-1 {
    background-color: var(--azurite);
    color: white;
}

.skill-level-2 {
    background-color: var(--bamboo);
    color: white;
}

.skill-level-3 {
    background-color: var(--cinnabar);
    color: white;
}

/* 古籍时间线 */
.timeline {
    margin-top: 3.5rem;
    position: relative;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 120px;
    top: 0;
    height: 100%;
    width: 1px;
    background-color: var(--ochre);
    opacity: 0.5;
}

.timeline-item {
    display: flex;
    margin-bottom: 2.5rem;
    position: relative;
}

.timeline-date {
    flex: 0 0 120px;
    font-weight: 700;
    color: var(--ochre);
    font-family: 'SimSun', serif;
    position: relative;
}

.timeline-date::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    background-color: var(--cinnabar);
    border-radius: 50%;
    border: 2px solid var(--paper);
}

.timeline-content {
    flex: 1;
    padding-left: 2rem;
}

.timeline-content h4 {
    margin-bottom: 0.5rem;
    color: var(--ink);
    display: inline-flex;
    align-items: center;
}

.timeline-content h4 i {
    margin-right: 0.5rem;
    font-size: 1.1em;
    color: var(--cinnabar);
}

/* 个人成就样式 - 古籍条目 */
.achievements {
    margin-top: 3.5rem;
}

.achievement-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.achievement-item i {
    margin-right: 0.5rem;
    color: var(--cinnabar);
    font-size: 1.2em;
}

.achievement-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    background-color: var(--ivory);
    padding: 1.2rem 1.5rem;
    border-radius: 0;
    border: 1px solid #e6e3dd;
    flex: 1;
    min-width: 200px;
    transition: all 0.3s ease;
}

.achievement-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border-color: var(--cinnabar);
}

  

/* 作品集区域样式 - 手卷式设计 */
.portfolio {
    padding: 8rem 0;
    background-color: var(--ivory);
    position: relative;
}

/* 手卷装饰 */
.portfolio::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 10px;
    background-color: var(--ochre);
    opacity: 0.3;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2.5rem;
    margin-top: 4rem;
}

/* 裱褙式作品卡片 */
.portfolio-item {
    background-color: var(--paper);
    border: 1px solid #e6e3dd;
    border-radius: 0;
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    position: relative;
}

.portfolio-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

/* 毛边纸边框效果 */
.portfolio-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.6s ease;
    position: relative;
    border-bottom: 1px solid #e6e3dd;
}

.portfolio-item:hover img {
    transform: scale(1.08);
}

.portfolio-info {
    padding: 1.8rem;
    background-color: white;
}

.portfolio-info h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    font-family: 'SimSun', serif;
    color: var(--ink);
    position: relative;
    padding-bottom: 0.5rem;
    border-bottom: none;
}

.portfolio-info h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 1px;
    background-color: var(--cinnabar);
}

.portfolio-info p {
    color: var(--ink);
    margin-bottom: 1.5rem;
    text-indent: 2em;
    line-height: 1.7;
    font-family: 'SimSun', serif;
}

/* 联系我区域样式 - 拜帖风格 */
.contact {
    padding: 8rem 0;
    background-color: var(--paper);
    position: relative;
}

.contact-content {
    display: flex;
    flex-wrap: wrap;
    gap: 4rem;
}

.contact-info {
    flex: 1;
    min-width: 300px;
    position: relative;
    padding: 2rem;
    background-color: white;
    border: 1px solid #e6e3dd;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
}

.contact-details {
    margin: 1.5rem 0;
}

.contact-details p {
    margin-bottom: 1.5rem;
    display: flex;
    align-items: flex-start;
    position: relative;
}

.contact-details i {
    margin-right: 1rem;
    font-size: 1.4rem;
    color: var(--cinnabar);
    margin-top: 5px;
}

.contact-details p span {
    font-family: 'SimSun', serif;
    color: var(--ink);
}

.social-links {
    display: flex;
    gap: 1.2rem;
    margin-top: 3rem;
    justify-content: center;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 0;
    background-color: var(--paper);
    color: var(--ink);
    font-size: 1.3rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    border: 1px solid #e6e3dd;
    transform: rotate(-1deg);
}

.social-links a:hover {
    background-color: var(--cinnabar);
    color: white;
    transform: rotate(1deg) scale(1.05);
}

.contact-form {
    flex: 1;
    min-width: 300px;
    position: relative;
}

.contact-form form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-form input,
.contact-form textarea {
    padding: 0.8rem 1rem;
    border: 1px solid #ddd;
    border-radius: 0;
    font-size: 1rem;
    width: 100%;
    transition: border-color 0.3s ease;
    background-color: white;
    font-family: 'SimSun', serif;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--cinnabar);
    background-color: var(--ivory);
}

.contact-form textarea {
    resize: vertical;
    min-height: 180px;
}

/* 页脚样式 - 简化版 */
footer {
    background-color: var(--paper);
    color: var(--ink);
    padding: 1rem 0;
    text-align: center;
    position: relative;
    border-top: 1px solid #e6e3dd;
}

footer p {
    font-family: 'SimSun', serif;
    color: var(--ink);
    opacity: 0.8;
    text-align: center;
    text-indent: 0;
}

/* 响应式设计 - 新中式适配 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 992px) {
    /* 适配平板 - 手卷布局调整 */
    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
    
    .about-content {
        gap: 3rem;
    }
    
    .contact-content {
        gap: 3rem;
    }
}

@media (max-width: 768px) {
    /* 适配移动设备 - 线装书菜单调整 */
    .nav-links {
        position: fixed;
        right: -100%;
        top: 70px;
        flex-direction: column;
        background-color: var(--paper);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
        border-top: 1px solid var(--ochre);
    }

    .nav-links.active {
        right: 0;
        animation: fadeIn 0.5s ease-out;
    }

    .nav-links li {
        margin: 1.5rem 0;
    }

    /* 古籍书签汉堡菜单 */
    .hamburger {
        display: block;
    }

    .bar {
        background-color: var(--ink);
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
        background-color: var(--cinnabar);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
        background-color: var(--cinnabar);
    }

    /* 单列手卷布局 */
    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    /* 适配移动设备的古籍标题 */
    h1 {
        font-size: 2rem;
        letter-spacing: 0.05em;
    }

    h2 {
        font-size: 1.8rem;
        letter-spacing: 0.05em;
    }

    /* 英雄区域标题适配 */
    .hero h1 {
        font-size: 2.5rem;
    }
    
    /* 移动端章节内容调整 */
    .about-text,
    .contact-info {
        padding: 1.5rem;
    }
}

@media (max-width: 576px) {
    /* 小屏移动设备适配 */
    .container {
        width: 90%;
    }

    /* 小屏标题调整 */
    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
        line-height: 1.6;
    }

    /* 小屏书签按钮 */
    .btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }

    /* 小屏头像调整 */
    .about-img img {
        width: 200px;
        height: 200px;
        border-width: 10px;
    }
    
    /* 小屏栏线装饰调整 */
    h2::before,
    h2::after {
        display: none;
    }
    
    /* 小屏页脚样式已简化 */
    
    /* 小屏社交链接 */
    .social-links {
        gap: 1rem;
    }
    
    .social-links a {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
}